﻿
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
		String path = request.getContextPath();
		String basePath = request.getScheme() + "://" + request.getServerName()
				+ ":" + request.getServerPort() + path + "/";
%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">

<title>main</title>
<LINK href="./css/style.css" type=text/css rel=stylesheet>
<script src="./js/WebCalendar.js" type="text/javascript"></script>
<script src="./js/main.js" type="text/javascript"></script>
<script src="./js/jquery-1.7.2.min.js" type="text/javascript"></script>
<script src="./js/jquery.validate.min.js" type="text/javascript"></script>
<script src="./js/validate.js" type="text/javascript"></script>
<style type="text/css">
<!--
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
	background-color: #5CB7FE;
}
.STYLE1 {font-size: 12px}
a:link {
	text-decoration: none;
}
a:visited {
	text-decoration: none;
}
a:hover {
	text-decoration: underline;
}
a:active {
	text-decoration: none;
}
.STYLE5 {font-size: 12px; color: #FF0000; }
.STYLE6 {
	font-size: 16px;
	font-weight: bold;
}
-->
 </style>
</head>
<script language="javascript">
$(document).ready(function() {
    $("#area").keydown(function(event) {
        var keyCode = event.which;
        if (keyCode == 46 || keyCode == 8 || keyCode == 190 || (keyCode >= 48 && keyCode <= 57) || (keyCode >= 96 && keyCode <= 105) || keyCode == 110) {
            return true;
        } else { return false; }
    }).focus(function() {
        this.style.imeMode = 'disabled';
    });
    $("#quantity").keydown(function(event) {
        var keyCode = event.which;
        if (keyCode == 46 || keyCode == 8 || (keyCode >= 48 && keyCode <= 57) || (keyCode >= 96 && keyCode <= 105) || keyCode == 110) {
            return true;
        } else { return false; }
    }).focus(function() {
        this.style.imeMode = 'disabled';
    });
});

function fn_checkSmt() {
    drawingNum = $("#drawingNum").val();
	if (drawingNum!="" && drawingNum.length > 30) {
		alert("图号长度不能大于30个字符");
		return false;
	}
	
	return true;
}
</script> 

<body style="overflow-x:hidden">
<table width="100%" height="568" border="0" cellpadding="0"
	cellspacing="0" bordercolor="#D8EDFF">
	<!--DWLayoutTable-->
	<tr>
		<td height="8" colspan="4" valign="top"></td>
		<td width="834" valign="top"></td>
		<td width="5" valign="top"></td>
	</tr>
	<tr>
		<td height="5" colspan="3" align="right" valign="top"><img
			src="images/icon1.jpg" width="6" height="5" /></td>
		<td colspan="2" valign="top"><img src="images/icon2.jpg" width="100%"
			height="5" /></td>
		<td valign="top"><img src="images/icon3.jpg" width="5" height="5" /></td>
	</tr>
	<tr>
		<td width="7" height="523">&nbsp;</td>
		<td width="5" align="right" valign="top" background="images/icon5.jpg"><img
			src="images/icon5.jpg" width="5" height="5" /></td>
		<td colspan="2" valign="top" bgcolor="#D8EDFF">&nbsp;</td>
		<td valign="top" background="images/main_bg.png">
		
		<table width="100%" border="0" cellpadding="0" cellspacing="0"
			bgcolor="#D8EDFF">
			<!--DWLayoutTable-->
			<tr>
				<td height="30" colspan="3" valign="middle"><span class="STYLE1"><a href="reportMgmt.action">[报表管理]</a> &rarr; [缺件统计表]</span></td>
				<td width="29">&nbsp;</td>
			</tr>
			<tr>
				<td height="59" colspan="3" align="center" valign="middle" class="STYLE6">缺件统计表</td>
				<td>&nbsp;</td>
			</tr>
			<tr>
				<td width="90" height="345">&nbsp;</td>
				<td width="90%" valign="top">
		<form name="searchform" id="searchform" method="post" action="report!repositoryWarnReport.action" onsubmit="return fn_checkSmt();">
			 <fieldset>
   				 <legend class="STYLE1"><img alt="查询" src="images/search.png"/> &nbsp;&nbsp;查 询</legend>
					<table>
						<tr>
						  <td width="8" align="right" valign="middle"></td>
						  <td align="right" valign="middle"><span class="STYLE1">图号：</span></td>
						  <td valign="middle"><input name="drawingNum" id="drawingNum" type="text" size="16" maxlength="20" style="width:80px; height:18px;" value="<s:property value="drawingNum"/>"/></td>
						  <td width="8" align="right" valign="middle"></td>
						  <td align="right" valign="middle"><span class="STYLE1">厂家名称：</span></td>
						  <td valign="middle"><input name="vendor" id="vendor" type="text" size="16" maxlength="20" style="width:100px; height:18px;" value="<s:property value="vendor"/>"/></td>
						   <td width="8" align="right" valign="middle"></td>
						  <td align="right" valign="middle"><span class="STYLE1">类别：</span></td>
						  <td valign="middle"><select id="repositoryType" name="repositoryType">
								<option value="0" <s:if test="repositoryType == 0">selected</s:if>>半成品</option>
								<option value="1" <s:if test="repositoryType == 1">selected</s:if>>成品</option>						  
						  </select></td>
						  <td width="8" align="right" valign="middle"></td>
						  <td width="8" align="right" valign="middle"><span class="STYLE1"></span></td>
						  <td align="center" valign="middle"><input name="submit" type="submit" class="btn1_mouseout" onMouseOver="this.className='btn1_mouseover'" onMouseOut="this.className='btn1_mouseout'" value=" 查 询 "></td>
						  <td><input name="search" type="hidden" value="true"/></td>
					  	</tr>
				  </table>
		  	 </fieldset>
		  </form>
				<FORM name="form1" method="post">
				<table width="100%" border=0 cellpadding=0 cellspacing=1
					bgcolor=5cb7fe>
					<!--DWLayoutTable-->
					<tr>
					    <td width="5%" height="50" align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1">序号</span></td>
						<td width="10%" height="50" align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1">图号 </span></td>
						<td width="10%" height="50"  align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1">厂家</span></td>
						<td width="8%" height="50"  align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1">单位面积 </span></td>
				   		<td width="8%" align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1">当前库存</span></td>
						<td width="8%" align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1">最低库存</span></td>	
					</tr>
					<s:iterator value="reports" status="st">
					<tr>
					  <td height="25" align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1"><s:property value="#st.count + (currentPage - 1) * pageSize"/></span></td>
					  <td height="25" align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1"><s:property value="drawingNum"/></span></td>
					  <td align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1"><s:property value="vendor"/></span></td>
					  <td align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1"><s:property value="unitArea"/></span></td>
					  <td align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1"><s:if test="repositoryType == 0"><s:property value="materialCount"/></s:if><s:else><s:property value="productCount"/></s:else></span></td>
					  <td align="center" valign="middle"
							bgcolor="#D8EDFF"><span class="STYLE1"><s:if test="repositoryType == 0"><s:property value="materialWarningCount"/></s:if><s:else><s:property value="prodWarningCount"/></s:else></span></td>
				  </tr>
				  </s:iterator>
				  <s:if test="pageBar != ''">
  		  		  <tr>
				  	<td height="25" colspan="14" align="center" valign="middle" bgcolor="#D8EDFF"><span class="STYLE1"><s:property value="pageBar" escape="false"/></span></td>
				  </tr>
				    </s:if>
				    <s:else>
					  <tr>
					  	<td height="25" colspan="14" align="center" valign="middle" bgcolor="#D8EDFF"><span class="STYLE1">无记录</span></td>
					  </tr>
				  </s:else>
				</table>
				</FORM>
				</td>
				<td width="50">&nbsp;</td>
				<td>&nbsp;</td>
			</tr>
</table>
		</td>
		<td valign="top" background="images/icon6.jpg"><img
			src="images/icon6.jpg" width="5" height="100" /></td>
	</tr>

	<tr>
		<td height="5"></td>
		<td valign="top"><img src="images/icon7.jpg" width="5" height="5" /></td>
		<td colspan="3" valign="top"><img src="images/icon8.jpg" width="100%"
			height="5" /></td>
		<td valign="top"><img src="images/icon9.jpg" width="5" height="5" /></td>
	</tr>
	<tr>
		<td height="2"></td>
		<td></td>
		<td width="1"></td>
		<td width="6"></td>
		<td></td>
		<td></td>
	</tr>
</table>
</body>
</html>
